package com.junjie.springcloud.controller;

import com.junjie.springcloud.entities.CommonResult;
import com.junjie.springcloud.entities.Payment;
import com.junjie.springcloud.service.PaymentService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @Author Yi Jun jie
 * @Date 2021/3/1 14:13
 */
@RestController
public class FeginController {

    @Resource
    private PaymentService paymentService;

    @GetMapping("consumer/openfeign/payment/{id}")
    public CommonResult<Payment> paymentSQL(@PathVariable("id") Long id) {
        return paymentService.paymentSql(id);
    }
}
